﻿<%@ page title="" language="C#" masterpagefile="MasterPage.master" autoeventwireup="true" inherits="th_admin_dsalemodify, App_Web_bgx0xzll" %>

<asp:Content ID="Content1" ContentPlaceHolderID="contentscript" Runat="Server">
    <style type="text/css">
        body{background:white}
    #formtihuokacard table{margin:auto}
    #formtihuokacard td{text-align:left}
    #address{width:450px}

    #formtihuokacard div.cardnum{font-size:14px;font-weight:bold;padding:10px 0px 10px 0px;text-align:center}
    
    .formfahuo{text-align:center}
    .formfahuo table{margin:auto}
    
    #express{width:200px;font-size:14px}
    #expressnum{width:200px;font-size:14px}
    #remark{width:96%;height:80px}
    </style>
    <script type="text/javascript">
        function window.onload() {
            var t="<%=core.setting.get("express")%>".split(",");
	        var i;

            
            $form.addOption("express","","请选择快递公司");
            for(i=0;i<t.length;i++)
            {
                $form.addOption("express",t[i],t[i]);
            }
            //window.open("xmldsale.aspx?dsaleid=" + $("#dsaleid").val());
            $form.ElementsDataFromXML("formfahuo", "xmldsale.aspx?dsaleid=" + $("#dsaleid").val());
            
            if($("#expresstime").val()=="")
            {
                $("#expresstime").val("<%=DateTime.Now.ToString()%>");
            }
            
            $("#urlhref").val(window.top.document.location);
            
            if (document.getElementById('express').value=="")
	        {
                $form.focusSelect("express",getCookie("express"));
	        }
	        __dsalestate_onchange();
        }
        
        function __checkform(evt)
        {

            return jsformcheck(evt, "formfahuo");

        }
        function __dsalestate_onchange()
        {

            var v=$form.getRadioValue("dsalestate");
            var t="express,expressnum".split(",");
            if (v=="0")
            {
                $("#divexpress").hide();
                for(i=0;i<t.length;i++)
                {
                    gE(t[i]).setAttribute("nullabled","true");
                }
            }
            else
            {
                $("#divexpress").show();
                for(i=0;i<t.length;i++)
                {
                    gE(t[i]).setAttribute("nullabled","false");
                }
            }
        }
    </script>

</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">
    <form id="formfahuo" onsubmit="javascript:return __checkform(event);" action="" method="post" target="_top">
        
        <fieldset><legend>发货状态</legend>
            <input type="radio" name="dsalestate" value="0" nullabled="false" alerttext="发货状态" onclick="javascript:__dsalestate_onchange();"/>未发货
            <input type="radio" name="dsalestate" value="1" onclick="javascript:__dsalestate_onchange();"/>已发货
            <div id="divexpress">
                <table>
                    <tr>
                        <td>快递公司</td>
                        <td>
                            <select name="express" id="express" alerttext="快递公司" nullabled="true"></select>
                            <a href="javascript:setCookie('express',document.getElementById('express').value);alert('记忆成功'+getCookie('express'));">记住当前快递公司，以便连续录入。</a>
                        </td>
                    </tr>
                    <tr>
                        <td>快递编号</td>
                        <td><input type="text" id="expressnum" name="expressnum" nullabled="true" maxlength="50" datatype="string" alerttext="快递编号"/></td>
                    </tr>
                    <tr>
                        <td>快递时间</td>
                        <td><input type="text" id="expresstime" name="expresstime" nullabled="true" maxlength="50" datatype="string" alerttext="快递时间" value=""/></td>
                    </tr>
                </table>
            </div>
        </fieldset>
        <fieldset><legend>收货人信息</legend>
        <table>
            <tr>
                <td>姓名</td>
                <td><input type="text" id="truename" name="truename" nullabled="false" maxlength="50" datatype="string" alerttext="姓名"/></td>
            </tr>
            <tr>
                <td>联系电话</td>
                <td><input type="text" id="phone" name="phone" nullabled="false" maxlength="50" datatype="string" alerttext="联系电话"/></td>
            </tr>
            <tr>
                <td>收货地址</td>
                <td><input type="text" id="address" name="address" nullabled="false" maxlength="255" datatype="string" alerttext="收货地址"/></td>
            </tr>
        </table>
        </fieldset>
        <fieldset><legend>备注</legend>
            <textarea id="remark" name="remark" cols="6" maxlength="500" alerttext="备注" nullabled="true"></textarea>
        </fieldset>   
        <div class="center"><input type="submit" value="提交" class="btn2" /><input id="dsaleid" name="dsaleid" type="hidden" value="<%=Request.QueryString["dsaleid"]%>" /><input id="urlhref" name="urlhref" type="hidden" value="" /></div>
    </form>
</asp:Content>

